﻿
using LPLS.DBEntities.ConfigModels.DeviceInfoModels;
using Prism.Mvvm;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DataCollectionConfigModule.ViewModels
{
    public  class PLCVarConfigViewModel : BindableBase
    {



        public PLCVarConfigViewModel()         
        {
            DataCollectionDeviceEvent.OnDataCollectionChangedEvent += DataCollectionDeviceEvent_OnDataCollectionChangedEvent;
        }

        private void DataCollectionDeviceEvent_OnDataCollectionChangedEvent(LPLS.DBEntities.ConfigModels.DeviceInfoModels.DeviceBaseInfo obj)
        {
            this.SelectDeviceModel = obj;
        }

        private DeviceBaseInfo _SelectDeviceModel;
        /// <summary>
        /// 选择的设备
        /// </summary>
        public DeviceBaseInfo SelectDeviceModel
        {
            get { return _SelectDeviceModel; }
            set { 
                SetProperty(ref _SelectDeviceModel, value);              
               }
        }


    }
}
